<%@ page import="cardbs.domain.Department" %>
<%@ page import="cardbs.domain.Work" %>
<%@ page import="java.util.*" %>
<%@ page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Ενημέρωση εργασίας</title>
<script type="text/javascript">
<!--

function validate_form ( )
{
    valid = true;
	if (document.updateWork.price.value <= 0 )
    {
        alert ("Παρακαλώ δώστε θετική τιμή εργασίας" );
        valid = false;
    }
   
    return valid;
}

//-->
</script>
</head>
<body>
<%
Work workForUpdate = (Work)session.getAttribute("workForUpdate");
String workForUpdateDescription = (String)session.getAttribute("workForUpdateDescription");
Double workForUpdatePrice = (Double)session.getAttribute("workForUpdatePrice");
String workForUpdateDepartmentCode = (String)session.getAttribute("workForUpdateDepartmentCode");
Department workForUpdateDepartment = (Department)session.getAttribute("workForUpdateDepartment");

 %>
 
 <FORM Name = "updateWork" action="/car-dbs-implementation/UpdateWorkPriceServlet" onsubmit="return validate_form()" method="post">
 <div align="center">
<jsp:include page="exitPage.jsp"/>
<table width="100%" border="0" cellspacing="0" cellpadding="0">

<tr>
					<td width="32%"><img
						src="../../images/loginPages/ΕνημέρωσηΕργασίας.png" alt="Service A.E."
						width="260" height="228" /></td>
					<td style="width: 206px" width="842">
<h2>Eνημέρωση της εργασίας με τα ακόλουθα χαρακτηριστικά (Τα πεδία που δεν είναι γαλάζια μπορούν να ενημερωθούν):</h2>
 <br>
  </td>
  </tr>
  </table>
  <table width="40%">
  <tr>
    <td width="12%">
    <td>Τμήμα που ανήκει η εργασία </td>
    <td><input type="text" name="department" STYLE="color: #FFFFFF; font-family: Verdana; font-weight: bold; font-size: 12px; background-color: #72A4D2;" size="10" maxlength="30" value=<%=workForUpdateDepartmentCode%> readonly="readonly"></td>
  </tr>
  <tr>
    <td width="12%">
    <td>Περιγραφή εργασίας </td>
    <td><textarea name="description" rows="3" cols="20" STYLE="color: #FFFFFF; font-family: Verdana; font-weight: bold; font-size: 12px; background-color: #72A4D2;" readonly="readonly"><%=workForUpdateDescription%></textarea></td>
  </tr>
  <tr>
    <td width="12%">
    <td >Τιμή εργασίας (ευρώ)</td>
    <td><input type="text" name="price" value=<%=workForUpdatePrice%>></td>
  </tr>
     
  <tr>
    <td>&nbsp;</td>
  </table>
  <table>
  <tr>
  <td width="12%">
  <td width="5%" width="56">
					<input TYPE="submit" VALUE="Ενημέρωση Εργασίας" style="width: 193px">
					</td>
					<td width="5%" width="56">
					<a href="/car-dbs-implementation/uipages/firstPagePages/HeadmasterViewLoginPage.jsp"><img src="../../images/CancelButton.png" style="border:1px solid black;"/></a>
	</td>
</tr>
</table>
</div>
</FORM>

</body>
</html>